<template>
  <!-- 书架里面的历史页面，没有登录接口，空白页面 -->
  <div class="history">
    <van-sticky>
      <van-nav-bar title="阅读历史" left-arrow>
        <template #left>
          <van-icon
            name="arrow-left"
            color="#ccc"
            @click="onClickLeft"
            size="18"
          />
        </template>
        <template #right>
          <div @click="onClickRight">清空</div>
        </template>
      </van-nav-bar>
    </van-sticky>
  </div>
</template>

<script>
import { Toast } from "vant";

export default {
  methods: {
    onClickLeft() {
		console.log(111);
      this.$emit("update-show-history", false);
    },
    onClickRight() {
      Toast("已清空");
    },
  },
};
</script>

<style lang="less" scoped>
.history {
  width: 100%;
  height: 100%;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 950;
  background: #f7f7f7;
  overflow: scroll;
}
</style>